#include <stdio.h>
int main() {
    int money,count=0,s=0;
    scanf("%d", &money);
    for(int a=0;a<=money/5;a++){
        for(int b = 0;b<=money/3;b++){
	        int c = money-a-b;
		    if(a*5+b*3+c/3==money&&c%3==0){
                count++;
                s = s+a;
            }
	    }
    }
    if(count!=0){
        printf("%d %d",count,s);
    }else{
        printf("%d -1",count);
    }
    return 0;
}
 